def sum_numbers(num):
    # 1.出口
    if num == 1:
        return 1
    # 2.数字累加num+（1...num-1）
    # 假设sum_numbers能够正确的处理1...num-1
    temp = sum_numbers(num-1)
    return num + temp


result = sum_numbers(1)
print(result)